gccfandomcom_ja-20200214-history
Struct cpp options
このページを編集する際は，編集に関する方針に従ってください． 概要 *gcc-4.1.0/libcpp/include/cpplib.hにて定義 実装 252 /* This structure is nested inside struct cpp_reader, and 253 carries all the options visible to the command line. */ 254 struct cpp_options 255 { 256 /* Characters between tab stops. */ 257 unsigned int tabstop; 258 *C言語の種類を表す **ANSI CだとかC99だとか 259 /* The language we're preprocessing. */ 260 enum c_lang lang; 261 262 /* Nonzero means use extra default include directories for C++. */ 263 unsigned char cplusplus; 264 265 /* Nonzero means handle cplusplus style comments. */ 266 unsigned char cplusplus_comments; 267 268 /* Nonzero means define __OBJC__, treat @ as a special token, and 269 use the OBJCPLUS_INCLUDE_PATH environment variable. */ 270 unsigned char objc; 271 272 /* Nonzero means don't copy comments into the output file. */ 273 unsigned char discard_comments; 274 275 /* Nonzero means don't copy comments into the output file during 276 macro expansion. */ 277 unsigned char discard_comments_in_macro_exp; 278 279 /* Nonzero means process the ISO trigraph sequences. */ 280 unsigned char trigraphs; 281 282 /* Nonzero means process the ISO digraph sequences. */ 283 unsigned char digraphs; 284 285 /* Nonzero means to allow hexadecimal floats and LL suffixes. */ 286 unsigned char extended_numbers; 287 288 /* Nonzero means print names of header files (-H). */ 289 unsigned char print_include_names; 290 291 /* Nonzero means cpp_pedwarn causes a hard error. */ 292 unsigned char pedantic_errors; 293 294 /* Nonzero means don't print warning messages. */ 295 unsigned char inhibit_warnings; 296 297 /* Nonzero means complain about deprecated features. */ 298 unsigned char warn_deprecated; 299 300 /* Nonzero means don't suppress warnings from system headers. */ 301 unsigned char warn_system_headers; 302 303 /* Nonzero means don't print error messages. Has no option to 304 select it, but can be set by a user of cpplib (e.g. fix-header). */ 305 unsigned char inhibit_errors; 306 307 /* Nonzero means warn if slash-star appears in a comment. */ 308 unsigned char warn_comments; 309 310 /* Nonzero means warn if a user-supplied include directory does not 311 exist. */ 312 unsigned char warn_missing_include_dirs; 313 314 /* Nonzero means warn if there are any trigraphs. */ 315 unsigned char warn_trigraphs; 316 317 /* Nonzero means warn about multicharacter charconsts. */ 318 unsigned char warn_multichar; 319 *真ならば警告を伝統的なCの形にする 320 /* Nonzero means warn about various incompatibilities with 321 traditional C. */ 322 unsigned char warn_traditional; 323 324 /* Nonzero means warn about long long numeric constants. */ 325 unsigned char warn_long_long; 326 327 /* Nonzero means warn about text after an #endif (or #else). */ 328 unsigned char warn_endif_labels; 329 330 /* Nonzero means warn about implicit sign changes owing to integer 331 promotions. */ 332 unsigned char warn_num_sign_change; 333 334 /* Zero means don't warn about __VA_ARGS__ usage in c89 pedantic mode. 335 Presumably the usage is protected by the appropriate #ifdef. */ 336 unsigned char warn_variadic_macros; 337 338 /* Nonzero means turn warnings into errors. */ 339 unsigned char warnings_are_errors; 340 341 /* Nonzero means we should look for header.gcc files that remap file 342 names. */ 343 unsigned char remap; 344 345 /* Zero means dollar signs are punctuation. */ 346 unsigned char dollars_in_ident; 347 348 /* Nonzero means UCNs are accepted in identifiers. */ 349 unsigned char extended_identifiers; 350 351 /* True if we should warn about dollars in identifiers or numbers 352 for this translation unit. */ 353 unsigned char warn_dollars; 354 355 /* Nonzero means warn if undefined identifiers are evaluated in an #if. */ 356 unsigned char warn_undef; 357 358 /* Nonzero means warn of unused macros from the main file. */ 359 unsigned char warn_unused_macros; 360 361 /* Nonzero for the 1999 C Standard, including corrigenda and amendments. */ 362 unsigned char c99; 363 364 /* Nonzero if we are conforming to a specific C or C++ standard. */ 365 unsigned char std; 366 *真ならばエラーメッセージをANSIに従った形にする 367 /* Nonzero means give all the error messages the ANSI standard requires. */ 368 unsigned char pedantic; 369 *非ゼロならばプリプロセシング済み 370 /* Nonzero means we're looking at already preprocessed code, so don't 371 bother trying to do macro expansion and whatnot. */ 372 unsigned char preprocessed; 373 *列 374 /* Print column number in error messages. */ 375 unsigned char show_column; 376 377 /* Nonzero means handle C++ alternate operator names. */ 378 unsigned char operator_names; 379 380 /* True for traditional preprocessing. */ 381 unsigned char traditional; 382 383 /* Holds the name of the target (execution) character set. */ 384 const char *narrow_charset; 385 386 /* Holds the name of the target wide character set. */ 387 const char *wide_charset; 388 389 /* Holds the name of the input character set. */ 390 const char *input_charset; 391 392 /* The minimum permitted level of normalization before a warning 393 is generated. */ 394 enum cpp_normalize_level warn_normalize; 395 396 /* True to warn about precompiled header files we couldn't use. */ 397 bool warn_invalid_pch; 398 399 /* True if dependencies should be restored from a precompiled header. */ 400 bool restore_pch_deps; 401 402 /* Dependency generation. */ 403 struct 404 { 405 /* Style of header dependencies to generate. */ 406 enum cpp_deps_style style; 407 408 /* Assume missing files are generated files. */ 409 bool missing_files; 410 411 /* Generate phony targets for each dependency apart from the first 412 one. */ 413 bool phony_targets; 414 415 /* If true, no dependency is generated on the main file. */ 416 bool ignore_main_file; 417 } deps; 418 419 /* Target-specific features set by the front end or client. */ 420 421 /* Precision for target CPP arithmetic, target characters, target 422 ints and target wide characters, respectively. */ 423 size_t precision, char_precision, int_precision, wchar_precision; 424 425 /* True means chars (wide chars) are unsigned. */ 426 bool unsigned_char, unsigned_wchar; 427 428 /* True if the most significant byte in a word has the lowest 429 address in memory. */ 430 bool bytes_big_endian; 431 432 /* Nonzero means __STDC__ should have the value 0 in system headers. */ 433 unsigned char stdc_0_in_system_headers; 434 435 /* True means return pragmas as tokens rather than processing 436 them directly. */ 437 bool defer_pragmas; 438 439 /* True means error callback should be used for diagnostics. */ 440 bool client_diagnostic; 441 };